{% extends "base.html" %}

{% block content %}
<div class="container-fluid">
    <div class="card">
        <div class="card-header d-flex justify-content-between align-items-center">
            <h5 class="mb-0">
                <i class="fas fa-user me-2"></i>个人信息设置
            </h5>
            <a href="{{ url_for('settings.settings_index') }}" class="btn btn-secondary">
                <i class="fas fa-arrow-left me-1"></i>返回
            </a>
        </div>
        <div class="card-body">
            <form method="post">
                <div class="mb-3">
                    <label for="username" class="form-label">用户名</label>
                    <input type="text" class="form-control" id="username" name="username" value="{{ current_user.username }}" required>
                </div>
                <div class="mb-3">
                    <label for="email" class="form-label">邮箱</label>
                    <input type="email" class="form-control" id="email" name="email" value="{{ current_user.email }}" required>
                </div>
                <div class="mb-3">
                    <label for="new_password" class="form-label">新密码（如需修改）</label>
                    <input type="password" class="form-control" id="new_password" name="new_password" minlength="6">
                    <div class="form-text">如果不需要修改密码，请留空</div>
                </div>
                <button type="submit" class="btn btn-primary">
                    <i class="fas fa-save me-1"></i>保存修改
                </button>
            </form>
        </div>
    </div>
</div>
{% endblock %} 